import { createApp } from "vue";
import mitt from "mitt";
import App from "./App.vue";
import "@/permission"; // permission control
import router from "./router";
import ElementPlus from "element-plus";
import "element-plus/dist/index.css";
import * as ElementPlusIconsVue from "@element-plus/icons-vue";
const bus = mitt();
const app = createApp(App);
app.config.globalProperties.$bus = bus
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component);
}
app.use(ElementPlus);

app.use(router).mount("#app");
